import Vue from 'vue'
import VueRouter from 'vue-router'


Vue.use(VueRouter)

const routes = [{
        path: '/login',
        component: () =>
            import ('@v/login/login.vue')
    },
    {
        path: "/",
        redirect: '/home',
        component: () =>
            import ('@v/layout/index.vue'),
        children: [{
                path: "home",
                component: () =>
                    import ( /* webpackChunkName: "home" */ '@v/layout/home/home.vue')
            },
            {
                path: "equip",
                component: () =>
                    import ( /* webpackChunkName: "equip" */ '@v/layout/equip/equip')
            },
            {
                path: "discount",
                component: () =>
                    import ( /* webpackChunkName: "discount" */ '@v/layout/discount/Discounts'),
                redirect: "discount/Jingxuan",
                children: [{
                        path: "Jingxuan",
                        component: () =>
                            import ('@v/layout/discount/Jingxuan')
                    },
                    {
                        path: "Cloths",
                        component: () =>
                            import ('@v/layout/discount/Cloths')
                    },
                    {
                        path: "Shuma",
                        component: () =>
                            import ('@v/layout/discount/Shuma')
                    },
                    {
                        path: "Shows",
                        component: () =>
                            import ('@v/layout/discount/Shows')
                    }
                ]
            },
            {
                path: "find",
                component: () =>
                    import ( /* webpackChunkName: "find" */ '@v/layout/find/find')
            },
            {
                path: "more",
                component: () =>
                    import ( /* webpackChunkName: "more" */ '@v/layout/more/more')
            },

        ]

    },
    // {
    //     path: "hotactive",
    //     component: () =>
    //         import ( /* webpackChunkName: "more" */ '@v/layout/hotactive')


    // }



]

const router = new VueRouter({
    mode: 'history',
    base: process.env.BASE_URL,
    routes
})

export default router